#

| Chapter 16 Where Did I Put That? |

## 16.4 List All Subdirectories with ls -R

By default, ls lists just one directory. If you name one or more directories on the command line, ls will list each one. The -R (uppercase R) option lists all subdirectories, recursively. That shows you the whole directory tree starting at the current directory (or the directories you name on the command line).

This list can get pretty long; you might want to pipe the output to a pager program like more (25.3). The ls -C option is a good idea, too, to list the output in columns. (When the ls output goes to a pipe, BSD versions of ls won't make output in columns automatically.)

- JP

16.3 Reordering ls Listings |  | 16.5 The Three UNIX File Times